//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package com.restaurant.application.indexes.couponlist.support;

import com.google.common.collect.Lists;
import com.nebutown.commonunits.dataface.definitions.TimeInterval;
import com.nebutown.generation.Convert;
import com.nebutown.generation.PickableBean;
import java.util.List;

public class SearchData implements PickableBean {
    public static final String FN_MODALITY = "modality";
    public static final String FN_NUMBER = "number";
    public static final String FN_COUPONSTATE = "couponState";
    public static final String FN_STATE = "state";
    public static final String FN_CREATETIME = "createTime";
    public static final String FN_USEDTIME = "usedTime";
    public static final String FN_CUSTOMERID = "customerId";
    public static final String FN_PHONE = "phone";
    public static final String FN_USEDCUSTOMERID = "usedCustomerId";
    public static final String FN_USEDPHONE = "usedPhone";
    public static final String FN_CUSTOMERUID = "customerUid";
    public static final String FN_PAGE = "page";
    public static final List<String> FIELD_NAMES = Lists.newArrayList(new String[]{"modality", "number", "couponState", "state", "createTime", "usedTime", "customerId", "phone", "usedCustomerId", "usedPhone", "customerUid", "page"});
    private String modality;
    private String number;
    private String couponState;
    private String state;
    private TimeInterval createTime;
    private TimeInterval usedTime;
    private String customerId;
    private String phone;
    private String usedCustomerId;
    private String usedPhone;
    private String customerUid;
    private Integer page;

    public SearchData(String modality, String number, String couponState, String state, TimeInterval createTime, TimeInterval usedTime, String customerId, String phone, String usedCustomerId, String usedPhone, String customerUid, Integer page) {
        this.setModality(modality);
        this.setNumber(number);
        this.setCouponState(couponState);
        this.setState(state);
        this.setCreateTime(createTime);
        this.setUsedTime(usedTime);
        this.setCustomerId(customerId);
        this.setPhone(phone);
        this.setUsedCustomerId(usedCustomerId);
        this.setUsedPhone(usedPhone);
        this.setCustomerUid(customerUid);
        this.setPage(page);
    }

    public SearchData() {
    }

    public SearchData duplicate() {
        SearchData result = new SearchData();
        result.modality = this.modality;
        result.number = this.number;
        result.couponState = this.couponState;
        result.state = this.state;
        result.createTime = this.createTime == null ? null : this.createTime.duplicate();
        result.usedTime = this.usedTime == null ? null : this.usedTime.duplicate();
        result.customerId = this.customerId;
        result.phone = this.phone;
        result.usedCustomerId = this.usedCustomerId;
        result.usedPhone = this.usedPhone;
        result.customerUid = this.customerUid;
        result.page = this.page;
        return result;
    }

    public String toString() {
        return Convert.toJson(this);
    }

    public String getModality() {
        return this.modality;
    }

    public void setModality(String value) {
        this.modality = value;
    }

    public SearchData withModality(String value) {
        this.setModality(value);
        return this;
    }

    public SearchData withModality(String value, String defaultValue) {
        this.setModality(value == null ? defaultValue : value);
        return this;
    }

    public String getNumber() {
        return this.number;
    }

    public void setNumber(String value) {
        this.number = value;
    }

    public SearchData withNumber(String value) {
        this.setNumber(value);
        return this;
    }

    public SearchData withNumber(String value, String defaultValue) {
        this.setNumber(value == null ? defaultValue : value);
        return this;
    }

    public String getCouponState() {
        return this.couponState;
    }

    public void setCouponState(String value) {
        this.couponState = value;
    }

    public SearchData withCouponState(String value) {
        this.setCouponState(value);
        return this;
    }

    public SearchData withCouponState(String value, String defaultValue) {
        this.setCouponState(value == null ? defaultValue : value);
        return this;
    }

    public String getState() {
        return this.state;
    }

    public void setState(String value) {
        this.state = value;
    }

    public SearchData withState(String value) {
        this.setState(value);
        return this;
    }

    public SearchData withState(String value, String defaultValue) {
        this.setState(value == null ? defaultValue : value);
        return this;
    }

    public TimeInterval getCreateTime() {
        return this.createTime;
    }

    public void setCreateTime(TimeInterval value) {
        this.createTime = value;
    }

    public SearchData withCreateTime(TimeInterval value) {
        this.setCreateTime(value);
        return this;
    }

    public SearchData withCreateTime(TimeInterval value, TimeInterval defaultValue) {
        this.setCreateTime(value == null ? defaultValue : value);
        return this;
    }

    public TimeInterval getUsedTime() {
        return this.usedTime;
    }

    public void setUsedTime(TimeInterval value) {
        this.usedTime = value;
    }

    public SearchData withUsedTime(TimeInterval value) {
        this.setUsedTime(value);
        return this;
    }

    public SearchData withUsedTime(TimeInterval value, TimeInterval defaultValue) {
        this.setUsedTime(value == null ? defaultValue : value);
        return this;
    }

    public String getCustomerId() {
        return this.customerId;
    }

    public void setCustomerId(String value) {
        this.customerId = value;
    }

    public SearchData withCustomerId(String value) {
        this.setCustomerId(value);
        return this;
    }

    public SearchData withCustomerId(String value, String defaultValue) {
        this.setCustomerId(value == null ? defaultValue : value);
        return this;
    }

    public String getPhone() {
        return this.phone;
    }

    public void setPhone(String value) {
        this.phone = value;
    }

    public SearchData withPhone(String value) {
        this.setPhone(value);
        return this;
    }

    public SearchData withPhone(String value, String defaultValue) {
        this.setPhone(value == null ? defaultValue : value);
        return this;
    }

    public String getUsedCustomerId() {
        return this.usedCustomerId;
    }

    public void setUsedCustomerId(String value) {
        this.usedCustomerId = value;
    }

    public SearchData withUsedCustomerId(String value) {
        this.setUsedCustomerId(value);
        return this;
    }

    public SearchData withUsedCustomerId(String value, String defaultValue) {
        this.setUsedCustomerId(value == null ? defaultValue : value);
        return this;
    }

    public String getUsedPhone() {
        return this.usedPhone;
    }

    public void setUsedPhone(String value) {
        this.usedPhone = value;
    }

    public SearchData withUsedPhone(String value) {
        this.setUsedPhone(value);
        return this;
    }

    public SearchData withUsedPhone(String value, String defaultValue) {
        this.setUsedPhone(value == null ? defaultValue : value);
        return this;
    }

    public String getCustomerUid() {
        return this.customerUid;
    }

    public void setCustomerUid(String value) {
        this.customerUid = value;
    }

    public SearchData withCustomerUid(String value) {
        this.setCustomerUid(value);
        return this;
    }

    public SearchData withCustomerUid(String value, String defaultValue) {
        this.setCustomerUid(value == null ? defaultValue : value);
        return this;
    }

    public Integer getPage() {
        return this.page;
    }

    public void setPage(Integer value) {
        this.page = value;
    }

    public SearchData withPage(Integer value) {
        this.setPage(value);
        return this;
    }

    public SearchData withPage(Integer value, Integer defaultValue) {
        this.setPage(value == null ? defaultValue : value);
        return this;
    }

    public Object getValueOf(String name) {
        byte var3 = -1;
        switch(name.hashCode()) {
            case -1772071022:
                if (name.equals("customerUid")) {
                    var3 = 10;
                }
                break;
            case -1581184615:
                if (name.equals("customerId")) {
                    var3 = 6;
                }
                break;
            case -1439168202:
                if (name.equals("usedCustomerId")) {
                    var3 = 8;
                }
                break;
            case -1034364087:
                if (name.equals("number")) {
                    var3 = 1;
                }
                break;
            case -622722335:
                if (name.equals("modality")) {
                    var3 = 0;
                }
                break;
            case -279409622:
                if (name.equals("usedTime")) {
                    var3 = 5;
                }
                break;
            case -75485263:
                if (name.equals("usedPhone")) {
                    var3 = 9;
                }
                break;
            case 3433103:
                if (name.equals("page")) {
                    var3 = 11;
                }
                break;
            case 106642798:
                if (name.equals("phone")) {
                    var3 = 7;
                }
                break;
            case 109757585:
                if (name.equals("state")) {
                    var3 = 3;
                }
                break;
            case 1369213417:
                if (name.equals("createTime")) {
                    var3 = 4;
                }
                break;
            case 1717838859:
                if (name.equals("couponState")) {
                    var3 = 2;
                }
        }

        switch(var3) {
            case 0:
                return this.getModality();
            case 1:
                return this.getNumber();
            case 2:
                return this.getCouponState();
            case 3:
                return this.getState();
            case 4:
                return this.getCreateTime();
            case 5:
                return this.getUsedTime();
            case 6:
                return this.getCustomerId();
            case 7:
                return this.getPhone();
            case 8:
                return this.getUsedCustomerId();
            case 9:
                return this.getUsedPhone();
            case 10:
                return this.getCustomerUid();
            case 11:
                return this.getPage();
            default:
                return null;
        }
    }

    public void setValueOf(String name, Object value) {
        byte var4 = -1;
        switch(name.hashCode()) {
            case -1772071022:
                if (name.equals("customerUid")) {
                    var4 = 10;
                }
                break;
            case -1581184615:
                if (name.equals("customerId")) {
                    var4 = 6;
                }
                break;
            case -1439168202:
                if (name.equals("usedCustomerId")) {
                    var4 = 8;
                }
                break;
            case -1034364087:
                if (name.equals("number")) {
                    var4 = 1;
                }
                break;
            case -622722335:
                if (name.equals("modality")) {
                    var4 = 0;
                }
                break;
            case -279409622:
                if (name.equals("usedTime")) {
                    var4 = 5;
                }
                break;
            case -75485263:
                if (name.equals("usedPhone")) {
                    var4 = 9;
                }
                break;
            case 3433103:
                if (name.equals("page")) {
                    var4 = 11;
                }
                break;
            case 106642798:
                if (name.equals("phone")) {
                    var4 = 7;
                }
                break;
            case 109757585:
                if (name.equals("state")) {
                    var4 = 3;
                }
                break;
            case 1369213417:
                if (name.equals("createTime")) {
                    var4 = 4;
                }
                break;
            case 1717838859:
                if (name.equals("couponState")) {
                    var4 = 2;
                }
        }

        switch(var4) {
            case 0:
                this.setModality((String)value);
                return;
            case 1:
                this.setNumber((String)value);
                return;
            case 2:
                this.setCouponState((String)value);
                return;
            case 3:
                this.setState((String)value);
                return;
            case 4:
                this.setCreateTime((TimeInterval)value);
                return;
            case 5:
                this.setUsedTime((TimeInterval)value);
                return;
            case 6:
                this.setCustomerId((String)value);
                return;
            case 7:
                this.setPhone((String)value);
                return;
            case 8:
                this.setUsedCustomerId((String)value);
                return;
            case 9:
                this.setUsedPhone((String)value);
                return;
            case 10:
                this.setCustomerUid((String)value);
                return;
            case 11:
                this.setPage((Integer)value);
                return;
            default:
        }
    }

    public boolean hasField(String name) {
        return FIELD_NAMES.contains(name);
    }

    public int hashCode() {
        return this.signature().hashCode();
    }

    public boolean equals(Object o) {
        return !(o instanceof SearchData) ? false : this.signature().equals(((SearchData)o).signature());
    }

    public String signature() {
        throw new RuntimeException("Bean SearchData has no signature defined, no hash code or equals possible.");
    }
}
